<html>
<head><meta charset="utf-8"><title>removing dependency on intern · wg-traits · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/index.html">wg-traits</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html">removing dependency on intern</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="189509005"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509005" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509005">(Mar 02 2020 at 16:38)</a>:</h4>
<p>Hey <span class="user-mention" data-user-id="232957">@Jack Huey</span> -- I'm inclined to merge <a href="https://github.com/rust-lang/chalk/pull/336" target="_blank" title="https://github.com/rust-lang/chalk/pull/336">https://github.com/rust-lang/chalk/pull/336</a>, any reason for me to hold off?</p>



<a name="189509236"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509236" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509236">(Mar 02 2020 at 16:40)</a>:</h4>
<p>as far as moving <code>ChalkIr</code> to <code>chalk-integration</code>, the only thing with that is tests in <code>chalk-ir</code> (or maybe <code>chalk-solve</code>, I don't remember)</p>



<a name="189509288"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509288" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509288">(Mar 02 2020 at 16:41)</a>:</h4>
<p>ah,</p>



<a name="189509293"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509293" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509293">(Mar 02 2020 at 16:41)</a>:</h4>
<p>those tests could probably move too</p>



<a name="189509299"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509299" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509299">(Mar 02 2020 at 16:41)</a>:</h4>
<p>but this PR is a good step anyway</p>



<a name="189509303"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509303" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509303">(Mar 02 2020 at 16:41)</a>:</h4>
<p>and maybe just fine</p>



<a name="189509381"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509381" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509381">(Mar 02 2020 at 16:42)</a>:</h4>
<p>I think the tests are good in <code>chalk-solve</code>, since they are testing things like <code>unify</code> IIRC</p>



<a name="189509440"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509440" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509440">(Mar 02 2020 at 16:42)</a>:</h4>
<p>it might be worth reexporting this from <code>chalk-integration</code> <code>lib.rs</code></p>



<a name="189509451"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509451" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509451">(Mar 02 2020 at 16:42)</a>:</h4>
<p>maybe a compromise would be</p>



<a name="189509475"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509475" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509475">(Mar 02 2020 at 16:42)</a>:</h4>
<p>making a crate that contains the <code>ChalkIr</code> type</p>



<a name="189509484"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509484" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509484">(Mar 02 2020 at 16:43)</a>:</h4>
<p>I mean a feature is also ok :)</p>



<a name="189509490"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509490" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509490">(Mar 02 2020 at 16:43)</a>:</h4>
<p>I'm not sure why I lean towards separate crates</p>



<a name="189509515"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509515" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509515">(Mar 02 2020 at 16:43)</a>:</h4>
<p>I guess it feels simpler to me somehow than features</p>



<a name="189509617"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509617" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509617">(Mar 02 2020 at 16:44)</a>:</h4>
<p>I think in this case a feature is simpler</p>



<a name="189509644"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509644" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509644">(Mar 02 2020 at 16:44)</a>:</h4>
<p>since it's <em>only</em> the default</p>



<a name="189509668"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509668" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509668">(Mar 02 2020 at 16:44)</a>:</h4>
<p>(if was more than just a struct, maybe a separate crate)</p>



<a name="189509725"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509725" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509725">(Mar 02 2020 at 16:45)</a>:</h4>
<p>I also found that I really wanted to make <code>StructId</code> and the like an associated type on <code>Interner</code>. But then <code>AssociatedTyValueId</code> (in <code>chalk-rust-ir</code> ) is different</p>



<a name="189509788"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509788" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509788">(Mar 02 2020 at 16:45)</a>:</h4>
<p>From what I've found with the rustc integration, wrapping all the <code>DefId</code>s gets a bit annoying</p>



<a name="189509831"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189509831" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189509831">(Mar 02 2020 at 16:46)</a>:</h4>
<p>but I guess it's okay</p>



<a name="189510221"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189510221" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189510221">(Mar 02 2020 at 16:50)</a>:</h4>
<p><span class="user-mention silent" data-user-id="232957">Jack Huey</span> <a href="#narrow/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern/near/189509788" title="#narrow/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern/near/189509788">said</a>:</p>
<blockquote>
<p>From what I've found with the rustc integration, wrapping all the <code>DefId</code>s gets a bit annoying</p>
</blockquote>
<p>wrapping?</p>



<a name="189510254"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189510254" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189510254">(Mar 02 2020 at 16:50)</a>:</h4>
<p>oh, right</p>



<a name="189510285"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189510285" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189510285">(Mar 02 2020 at 16:50)</a>:</h4>
<p>I was considering the idea of moving all those types (<code>FooId</code>) into associated types of <code>TypeFamily</code></p>



<a name="189510289"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189510289" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189510289">(Mar 02 2020 at 16:50)</a>:</h4>
<p>so that under the hood, they could all map to the same <code>DefId</code> type</p>



<a name="189510296"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189510296" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189510296">(Mar 02 2020 at 16:50)</a>:</h4>
<p>but all the generic code can still keep them separated</p>



<a name="189510320"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189510320" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189510320">(Mar 02 2020 at 16:51)</a>:</h4>
<p>(and <code>ChalkIr</code> could even use distinct types, if we wanted)</p>



<a name="189510329"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189510329" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189510329">(Mar 02 2020 at 16:51)</a>:</h4>
<p>would that make things simpler?</p>



<a name="189510484"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189510484" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189510484">(Mar 02 2020 at 16:52)</a>:</h4>
<p><span class="user-mention silent" data-user-id="232957">Jack Huey</span> <a href="#narrow/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern/near/189509725" title="#narrow/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern/near/189509725">said</a>:</p>
<blockquote>
<p>I also found that I really wanted to make <code>StructId</code> and the like an associated type on <code>Interner</code>. But then <code>AssociatedTyValueId</code> (in <code>chalk-rust-ir</code> ) is different</p>
</blockquote>



<a name="189510497"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189510497" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189510497">(Mar 02 2020 at 16:52)</a>:</h4>
<p><code>TypeFamily</code> =&gt; <code>Interner</code></p>



<a name="189511146"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/removing%20dependency%20on%20intern/near/189511146" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jack Huey <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/removing.20dependency.20on.20intern.html#189511146">(Mar 02 2020 at 16:59)</a>:</h4>
<p>Short answer: yes, it would be simpler for everything but <code>AssociatedTyValueId</code>, and therefore inconsistent</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>